#ifndef UTILS_H
#define UTILS_H

#include <QDateTime>
#include <QString>
#include <QDir>

namespace FsxWsUtils {

//! Misc. utility methods
class Utils
{
public:
    //! UTC to local time zone difference in seconds, UTC+1 => 3600.
    /*! \returns UTC difference in seconds, UTC+2 => 7200 */
    static const int utcDifferenceS();
    //! UTC to local time zone difference in seconds, UTC+1 => +01:00.
    /*! \returns UTC difference in hh:mm, UTC+2 => +02:00 */
    static const QString utcDifferenceHourMin();
    //! Timeframe timestamp (now -timeFrame).
    /*! \param timeFrameMs time frame
        \returns epoch timestamp */
    static const qint64 timeframe(const qint64 timeFrameMs);
    //! String to boolean.
    /*! \param boolCandidate
        \return bool */
    static const bool stringToBoolean(QString boolCandidate);
    //! YYYY MM DD hh:mm:ss timestamp
    /*! \param utc UTC or local time */
    static const QString timestamp(bool utc);
    //! Check if directory is valid
    /*! \param directory
        \return bool */
    static const bool isValidFmcDataDirectory(QString directory);
};
}
#endif // UTILS_H
